// All material copyright Esri, All Rights Reserved, unless otherwise specified.
// See https://js.arcgis.com/4.29/esri/copyright.txt for details.
//>>built
define(["exports", "./_commonjsHelpers"], function (Qa, K) {
    var ka = {exports: {}};
    (function (Ra, la) {
        la = (() => {
            var ma = "undefined" !== typeof document && document.currentScript ? document.currentScript.src : void 0;
            return function (ba = {}) {

                function fetch(url, opt) {
                    return new Promise(function (resolve, reject) {
                        var xhr = new XMLHttpRequest
                        xhr.onload = function () {
                            const res = new Response(xhr.response, {status: xhr.status})
                            resolve(res)
                        }
                        xhr.onerror = function (e) {
                            console.log("錯誤", url, e)
                            reject(new TypeError('Local request failed'))
                        }
                        xhr.open('GET', url)
                        if (!url.endsWith('.json')&&!url.endsWith('.js')) {
                            xhr.responseType = "arraybuffer";
                        }
                        xhr.send(null)
                    })
                }

                function Sa(a) {
                    return f.locateFile ? f.locateFile(a, z) : z + a
                }

                function na() {
                    var a = R.buffer;
                    f.HEAP8 = D = new Int8Array(a);
                    f.HEAP16 = H = new Int16Array(a);
                    f.HEAP32 = E = new Int32Array(a);
                    f.HEAPU8 = r = new Uint8Array(a);
                    f.HEAPU16 = S = new Uint16Array(a);
                    f.HEAPU32 = q = new Uint32Array(a);
                    f.HEAPF32 = oa = new Float32Array(a);
                    f.HEAPF64 = pa = new Float64Array(a)
                }

                function T(a) {
                    if (f.onAbort) f.onAbort(a);
                    a = "Aborted(" + a + ")";
                    I(a);
                    qa = !0;
                    a = new WebAssembly.RuntimeError(a + ". Build with -sASSERTIONS for more info.");
                    U(a);
                    throw a;
                }

                function ra(a) {
                    try {
                        if (a == L && M) return new Uint8Array(M);
                        if (ca) return ca(a);
                        throw "both async and sync fetching of the wasm failed";
                    } catch (b) {
                        T(b)
                    }
                }

                function Ta(a) {
                    return M || !sa && !V || "function" != typeof fetch ? Promise.resolve().then(() => ra(a)) : fetch(a, {credentials: "same-origin"}).then(b => {
                        if (!b.ok) throw "failed to load wasm binary file at '" +
                        a + "'";
                        return b.arrayBuffer()
                    }).catch(() => ra(a))
                }

                function ta(a, b, c) {
                    return Ta(a).then(d => WebAssembly.instantiate(d, b)).then(d => d).then(c, d => {
                        I("failed to asynchronously prepare wasm: " + d);
                        T(d)
                    })
                }

                function Ua(a, b, c, d) {
                    return a || "function" != typeof WebAssembly.instantiateStreaming || b.startsWith("data:application/octet-stream;base64,") || "function" != typeof fetch ? ta(b, c, d) : fetch(b, {credentials: "same-origin"}).then(e => WebAssembly.instantiateStreaming(e, c).then(d, function (g) {
                        I("wasm streaming compile failed: " +
                            g);
                        I("falling back to ArrayBuffer instantiation");
                        return ta(b, c, d)
                    }))
                }

                function da(a) {
                    for (; 0 < a.length;) a.shift()(f)
                }

                function ea(a) {
                    var b = W[a];
                    b || (a >= W.length && (W.length = a + 1), W[a] = b = ua.get(a));
                    return b
                }

                function Va(a) {
                    this.excPtr = a;
                    this.ptr = a - 24;
                    this.set_type = function (b) {
                        q[this.ptr + 4 >> 2] = b
                    };
                    this.get_type = function () {
                        return q[this.ptr + 4 >> 2]
                    };
                    this.set_destructor = function (b) {
                        q[this.ptr + 8 >> 2] = b
                    };
                    this.get_destructor = function () {
                        return q[this.ptr + 8 >> 2]
                    };
                    this.set_caught = function (b) {
                        D[this.ptr + 12 >> 0] = b ? 1 : 0
                    };
                    this.get_caught =
                        function () {
                            return 0 != D[this.ptr + 12 >> 0]
                        };
                    this.set_rethrown = function (b) {
                        D[this.ptr + 13 >> 0] = b ? 1 : 0
                    };
                    this.get_rethrown = function () {
                        return 0 != D[this.ptr + 13 >> 0]
                    };
                    this.init = function (b, c) {
                        this.set_adjusted_ptr(0);
                        this.set_type(b);
                        this.set_destructor(c)
                    };
                    this.set_adjusted_ptr = function (b) {
                        q[this.ptr + 16 >> 2] = b
                    };
                    this.get_adjusted_ptr = function () {
                        return q[this.ptr + 16 >> 2]
                    };
                    this.get_exception_ptr = function () {
                        if (va(this.get_type())) return q[this.excPtr >> 2];
                        var b = this.get_adjusted_ptr();
                        return 0 !== b ? b : this.excPtr
                    }
                }

                function wa(a) {
                    for (; a.length;) {
                        var b =
                            a.pop();
                        a.pop()(b)
                    }
                }

                function X(a) {
                    return this.fromWireType(E[a >> 2])
                }

                function Wa(a) {
                    if (void 0 === a) return "_unknown";
                    a = a.replace(/[^a-zA-Z0-9_]/g, "$");
                    var b = a.charCodeAt(0);
                    return 48 <= b && 57 >= b ? "_" + a : a
                }

                function Xa(a, b) {
                    a = Wa(a);
                    return {
                        [a]: function () {
                            return b.apply(this, arguments)
                        }
                    }[a]
                }

                function fa(a, b) {
                    var c = Xa(b, function (d) {
                        this.name = b;
                        this.message = d;
                        d = Error(d).stack;
                        void 0 !== d && (this.stack = this.toString() + "\n" + d.replace(/^Error(:[^\n]*)?\n/, ""))
                    });
                    c.prototype = Object.create(a.prototype);
                    c.prototype.constructor =
                        c;
                    c.prototype.toString = function () {
                        return void 0 === this.message ? this.name : this.name + ": " + this.message
                    };
                    return c
                }

                function xa(a, b, c) {
                    function d(l) {
                        l = c(l);
                        if (l.length !== a.length) throw new ha("Mismatched type converter count");
                        for (var h = 0; h < a.length; ++h) A(a[h], l[h])
                    }

                    a.forEach(function (l) {
                        Y[l] = b
                    });
                    var e = Array(b.length), g = [], k = 0;
                    b.forEach((l, h) => {
                        F.hasOwnProperty(l) ? e[h] = F[l] : (g.push(l), J.hasOwnProperty(l) || (J[l] = []), J[l].push(() => {
                            e[h] = F[l];
                            ++k;
                            k === g.length && d(e)
                        }))
                    });
                    0 === g.length && d(e)
                }

                function ia(a) {
                    switch (a) {
                        case 1:
                            return 0;
                        case 2:
                            return 1;
                        case 4:
                            return 2;
                        case 8:
                            return 3;
                        default:
                            throw new TypeError("Unknown type size: " + a);
                    }
                }

                function t(a) {
                    for (var b = ""; r[a];) b += ya[r[a++]];
                    return b
                }

                function v(a) {
                    throw new za(a);
                }

                function A(a, b, c = {}) {
                    if (!("argPackAdvance" in b)) throw new TypeError("registerType registeredInstance requires argPackAdvance");
                    var d = b.name;
                    a || v('type "' + d + '" must have a positive integer typeid pointer');
                    if (F.hasOwnProperty(a)) {
                        if (c.ignoreDuplicateRegistrations) return;
                        v("Cannot register type '" + d + "' twice")
                    }
                    F[a] =
                        b;
                    delete Y[a];
                    J.hasOwnProperty(a) && (b = J[a], delete J[a], b.forEach(e => e()))
                }

                function Aa(a) {
                    a >= x.reserved && 0 === --x.get(a).refcount && x.free(a)
                }

                function Ya(a, b) {
                    switch (b) {
                        case 2:
                            return function (c) {
                                return this.fromWireType(oa[c >> 2])
                            };
                        case 3:
                            return function (c) {
                                return this.fromWireType(pa[c >> 3])
                            };
                        default:
                            throw new TypeError("Unknown float type: " + a);
                    }
                }

                function Za(a, b, c, d, e, g) {
                    g = b.length;
                    2 > g && v("argTypes array size mismatch! Must at least get return value and 'this' types!");
                    var k = null !== b[1] && null !== c, l =
                        !1;
                    for (c = 1; c < b.length; ++c) if (null !== b[c] && void 0 === b[c].destructorFunction) {
                        l = !0;
                        break
                    }
                    var h = "void" !== b[0].name, n = g - 2, m = Array(n), p = [], w = [];
                    return function () {
                        arguments.length !== n && v("function " + a + " called with " + arguments.length + " arguments, expected " + n + " args!");
                        w.length = 0;
                        p.length = k ? 2 : 1;
                        p[0] = e;
                        if (k) {
                            var y = b[1].toWireType(w, this);
                            p[1] = y
                        }
                        for (var u = 0; u < n; ++u) m[u] = b[u + 2].toWireType(w, arguments[u]), p.push(m[u]);
                        u = d.apply(null, p);
                        if (l) wa(w); else for (var C = k ? 1 : 2; C < b.length; C++) {
                            var N = 1 === C ? y : m[C - 2];
                            null !==
                            b[C].destructorFunction && b[C].destructorFunction(N)
                        }
                        y = h ? b[0].fromWireType(u) : void 0;
                        return y
                    }
                }

                function $a(a, b, c) {
                    if (void 0 === a[b].overloadTable) {
                        var d = a[b];
                        a[b] = function () {
                            a[b].overloadTable.hasOwnProperty(arguments.length) || v("Function '" + c + "' called with an invalid number of arguments (" + arguments.length + ") - expects one of (" + a[b].overloadTable + ")!");
                            return a[b].overloadTable[arguments.length].apply(this, arguments)
                        };
                        a[b].overloadTable = [];
                        a[b].overloadTable[d.argCount] = d
                    }
                }

                function ab(a, b, c) {
                    f.hasOwnProperty(a) ?
                        ((void 0 === c || void 0 !== f[a].overloadTable && void 0 !== f[a].overloadTable[c]) && v("Cannot register public name '" + a + "' twice"), $a(f, a, a), f.hasOwnProperty(c) && v("Cannot register multiple overloads of a function with the same number of arguments (" + c + ")!"), f[a].overloadTable[c] = b) : (f[a] = b, void 0 !== c && (f[a].numArguments = c))
                }

                function bb(a, b) {
                    for (var c = [], d = 0; d < a; d++) c.push(q[b + 4 * d >> 2]);
                    return c
                }

                function cb(a, b) {
                    var c = [];
                    return function () {
                        c.length = 0;
                        Object.assign(c, arguments);
                        if (a.includes("j")) {
                            var d = f["dynCall_" +
                            a];
                            d = c && c.length ? d.apply(null, [b].concat(c)) : d.call(null, b)
                        } else d = ea(b).apply(null, c);
                        return d
                    }
                }

                function O(a, b) {
                    a = t(a);
                    var c = a.includes("j") ? cb(a, b) : ea(b);
                    "function" != typeof c && v("unknown function pointer with signature " + a + ": " + b);
                    return c
                }

                function Ba(a) {
                    a = Ca(a);
                    var b = t(a);
                    B(a);
                    return b
                }

                function db(a, b) {
                    function c(g) {
                        e[g] || F[g] || (Y[g] ? Y[g].forEach(c) : (d.push(g), e[g] = !0))
                    }

                    var d = [], e = {};
                    b.forEach(c);
                    throw new Da(a + ": " + d.map(Ba).join([", "]));
                }

                function eb(a, b, c) {
                    switch (b) {
                        case 0:
                            return c ? function (d) {
                                    return D[d]
                                } :
                                function (d) {
                                    return r[d]
                                };
                        case 1:
                            return c ? function (d) {
                                return H[d >> 1]
                            } : function (d) {
                                return S[d >> 1]
                            };
                        case 2:
                            return c ? function (d) {
                                return E[d >> 2]
                            } : function (d) {
                                return q[d >> 2]
                            };
                        default:
                            throw new TypeError("Unknown integer type: " + a);
                    }
                }

                function Ea(a, b, c) {
                    var d = b + c;
                    for (c = b; a[c] && !(c >= d);) ++c;
                    if (16 < c - b && a.buffer && Fa) return Fa.decode(a.subarray(b, c));
                    for (d = ""; b < c;) {
                        var e = a[b++];
                        if (e & 128) {
                            var g = a[b++] & 63;
                            if (192 == (e & 224)) d += String.fromCharCode((e & 31) << 6 | g); else {
                                var k = a[b++] & 63;
                                e = 224 == (e & 240) ? (e & 15) << 12 | g << 6 | k :
                                    (e & 7) << 18 | g << 12 | k << 6 | a[b++] & 63;
                                65536 > e ? d += String.fromCharCode(e) : (e -= 65536, d += String.fromCharCode(55296 | e >> 10, 56320 | e & 1023))
                            }
                        } else d += String.fromCharCode(e)
                    }
                    return d
                }

                function fb(a, b) {
                    var c = a >> 1;
                    for (var d = c + b / 2; !(c >= d) && S[c];) ++c;
                    c <<= 1;
                    if (32 < c - a && Ga) return Ga.decode(r.subarray(a, c));
                    c = "";
                    for (d = 0; !(d >= b / 2); ++d) {
                        var e = H[a + 2 * d >> 1];
                        if (0 == e) break;
                        c += String.fromCharCode(e)
                    }
                    return c
                }

                function gb(a, b, c) {
                    void 0 === c && (c = 2147483647);
                    if (2 > c) return 0;
                    c -= 2;
                    var d = b;
                    c = c < 2 * a.length ? c / 2 : a.length;
                    for (var e = 0; e < c; ++e) {
                        var g =
                            a.charCodeAt(e);
                        H[b >> 1] = g;
                        b += 2
                    }
                    H[b >> 1] = 0;
                    return b - d
                }

                function hb(a) {
                    return 2 * a.length
                }

                function ib(a, b) {
                    for (var c = 0, d = ""; !(c >= b / 4);) {
                        var e = E[a + 4 * c >> 2];
                        if (0 == e) break;
                        ++c;
                        65536 <= e ? (e -= 65536, d += String.fromCharCode(55296 | e >> 10, 56320 | e & 1023)) : d += String.fromCharCode(e)
                    }
                    return d
                }

                function jb(a, b, c) {
                    void 0 === c && (c = 2147483647);
                    if (4 > c) return 0;
                    var d = b;
                    c = d + c - 4;
                    for (var e = 0; e < a.length; ++e) {
                        var g = a.charCodeAt(e);
                        if (55296 <= g && 57343 >= g) {
                            var k = a.charCodeAt(++e);
                            g = 65536 + ((g & 1023) << 10) | k & 1023
                        }
                        E[b >> 2] = g;
                        b += 4;
                        if (b + 4 > c) break
                    }
                    E[b >>
                    2] = 0;
                    return b - d
                }

                function kb(a) {
                    for (var b = 0, c = 0; c < a.length; ++c) {
                        var d = a.charCodeAt(c);
                        55296 <= d && 57343 >= d && ++c;
                        b += 4
                    }
                    return b
                }

                function Ha() {
                    function a() {
                        if (!Z && (Z = !0, f.calledRun = !0, !qa)) {
                            da(Ia);
                            Ja(f);
                            if (f.onRuntimeInitialized) f.onRuntimeInitialized();
                            if (f.postRun) for ("function" == typeof f.postRun && (f.postRun = [f.postRun]); f.postRun.length;) Ka.unshift(f.postRun.shift());
                            da(Ka)
                        }
                    }

                    if (!(0 < G)) {
                        if (f.preRun) for ("function" == typeof f.preRun && (f.preRun = [f.preRun]); f.preRun.length;) La.unshift(f.preRun.shift());
                        da(La);
                        0 < G || (f.setStatus ? (f.setStatus("Running..."), setTimeout(function () {
                            setTimeout(function () {
                                f.setStatus("")
                            }, 1);
                            a()
                        }, 1)) : a())
                    }
                }

                var f = "undefined" != typeof ba ? ba : {}, Ja, U;
                f.ready = new Promise((a, b) => {
                    Ja = a;
                    U = b
                });
                var Ma = Object.assign({}, f), sa = "object" == typeof window, V = "function" == typeof importScripts;
                "object" == typeof process && "object" == typeof process.versions && "string" == typeof process.versions.node;
                var z = "", ca;
                if (sa || V) V ? z = self.location.href : "undefined" != typeof document && document.currentScript && (z = document.currentScript.src),
                ma && (z = ma), z = 0 !== z.indexOf("blob:") ? z.substr(0, z.replace(/[?#].*/, "").lastIndexOf("/") + 1) : "", V && (ca = a => {
                    var b = new XMLHttpRequest;
                    b.open("GET", a, !1);
                    b.responseType = "arraybuffer";
                    b.send(null);
                    return new Uint8Array(b.response)
                });
                var lb = f.print || console.log.bind(console), I = f.printErr || console.warn.bind(console);
                Object.assign(f, Ma);
                Ma = null;
                f.arguments && f.arguments;
                f.thisProgram && f.thisProgram;
                f.quit && f.quit;
                var M;
                f.wasmBinary && (M = f.wasmBinary);
                f.noExitRuntime || !0;
                "object" != typeof WebAssembly && T("no native wasm support detected");
                var R, qa = !1, D, r, H, S, E, q, oa, pa, ua, La = [], Ia = [], Ka = [], G = 0, P = null;
                var L = "i3s.wasm";
                L.startsWith("data:application/octet-stream;base64,") || (L = Sa(L));
                var W = [], Na = 0, aa = {}, J = {}, F = {}, Y = {}, ha = void 0, ya = void 0, za = void 0,
                    x = new function () {
                        this.allocated = [void 0];
                        this.freelist = [];
                        this.get = function (a) {
                            return this.allocated[a]
                        };
                        this.allocate = function (a) {
                            let b = this.freelist.pop() || this.allocated.length;
                            this.allocated[b] = a;
                            return b
                        };
                        this.free = function (a) {
                            this.allocated[a] = void 0;
                            this.freelist.push(a)
                        }
                    }, Q = {
                        toValue: a => {
                            a || v("Cannot use deleted val. handle \x3d " + a);
                            return x.get(a).value
                        }, toHandle: a => {
                            switch (a) {
                                case void 0:
                                    return 1;
                                case null:
                                    return 2;
                                case !0:
                                    return 3;
                                case !1:
                                    return 4;
                                default:
                                    return x.allocate({refcount: 1, value: a})
                            }
                        }
                    }, Da = void 0, Fa = "undefined" != typeof TextDecoder ? new TextDecoder("utf8") : void 0,
                    Ga = "undefined" != typeof TextDecoder ? new TextDecoder("utf-16le") : void 0, mb = {},
                    nb = [null, [], []];
                ha = f.InternalError = fa(Error, "InternalError");
                (function () {
                    for (var a = Array(256), b = 0; 256 > b; ++b) a[b] = String.fromCharCode(b);
                    ya = a
                })();
                za = f.BindingError = fa(Error, "BindingError");
                x.allocated.push({value: void 0}, {value: null}, {value: !0}, {value: !1});
                x.reserved = x.allocated.length;
                f.count_emval_handles = function () {
                    for (var a = 0, b = x.reserved; b < x.allocated.length; ++b) void 0 !== x.allocated[b] && ++a;
                    return a
                };
                Da = f.UnboundTypeError = fa(Error, "UnboundTypeError");
                var Pa = {
                    __call_sighandler: function (a, b) {
                        ea(a)(b)
                    }, __cxa_throw: function (a, b, c) {
                        (new Va(a)).init(b, c);
                        Na = a;
                        throw Na;
                    }, _embind_finalize_value_object: function (a) {
                        var b = aa[a];
                        delete aa[a];
                        var c = b.rawConstructor, d = b.rawDestructor, e = b.fields,
                            g = e.map(k => k.getterReturnType).concat(e.map(k => k.setterArgumentType));
                        xa([a], g, k => {
                            var l = {};
                            e.forEach((h, n) => {
                                var m = k[n], p = h.getter, w = h.getterContext, y = k[n + e.length], u = h.setter,
                                    C = h.setterContext;
                                l[h.fieldName] = {
                                    read: N => m.fromWireType(p(w, N)), write: (N, ob) => {
                                        var Oa = [];
                                        u(C, N, y.toWireType(Oa, ob));
                                        wa(Oa)
                                    }
                                }
                            });
                            return [{
                                name: b.name, fromWireType: function (h) {
                                    var n = {}, m;
                                    for (m in l) n[m] = l[m].read(h);
                                    d(h);
                                    return n
                                }, toWireType: function (h, n) {
                                    for (var m in l) if (!(m in
                                        n)) throw new TypeError('Missing field:  "' + m + '"');
                                    var p = c();
                                    for (m in l) l[m].write(p, n[m]);
                                    null !== h && h.push(d, p);
                                    return p
                                }, argPackAdvance: 8, readValueFromPointer: X, destructorFunction: d
                            }]
                        })
                    }, _embind_register_bigint: function (a, b, c, d, e) {
                    }, _embind_register_bool: function (a, b, c, d, e) {
                        var g = ia(c);
                        b = t(b);
                        A(a, {
                            name: b, fromWireType: function (k) {
                                return !!k
                            }, toWireType: function (k, l) {
                                return l ? d : e
                            }, argPackAdvance: 8, readValueFromPointer: function (k) {
                                if (1 === c) var l = D; else if (2 === c) l = H; else if (4 === c) l = E; else throw new TypeError("Unknown boolean type size: " +
                                    b);
                                return this.fromWireType(l[k >> g])
                            }, destructorFunction: null
                        })
                    }, _embind_register_emval: function (a, b) {
                        b = t(b);
                        A(a, {
                            name: b, fromWireType: function (c) {
                                var d = Q.toValue(c);
                                Aa(c);
                                return d
                            }, toWireType: function (c, d) {
                                return Q.toHandle(d)
                            }, argPackAdvance: 8, readValueFromPointer: X, destructorFunction: null
                        })
                    }, _embind_register_float: function (a, b, c) {
                        c = ia(c);
                        b = t(b);
                        A(a, {
                            name: b, fromWireType: function (d) {
                                return d
                            }, toWireType: function (d, e) {
                                return e
                            }, argPackAdvance: 8, readValueFromPointer: Ya(b, c), destructorFunction: null
                        })
                    },
                    _embind_register_function: function (a, b, c, d, e, g, k) {
                        var l = bb(b, c);
                        a = t(a);
                        e = O(d, e);
                        ab(a, function () {
                            db("Cannot call " + a + " due to unbound types", l)
                        }, b - 1);
                        xa([], l, function (h) {
                            var n = [h[0], null].concat(h.slice(1));
                            h = a;
                            n = Za(a, n, null, e, g);
                            var m = b - 1;
                            if (!f.hasOwnProperty(h)) throw new ha("Replacing nonexistant public symbol");
                            void 0 !== f[h].overloadTable && void 0 !== m ? f[h].overloadTable[m] = n : (f[h] = n, f[h].argCount = m);
                            return []
                        })
                    }, _embind_register_integer: function (a, b, c, d, e) {
                        b = t(b);
                        e = ia(c);
                        var g = l => l;
                        if (0 === d) {
                            var k =
                                32 - 8 * c;
                            g = l => l << k >>> k
                        }
                        c = b.includes("unsigned") ? function (l, h) {
                            return h >>> 0
                        } : function (l, h) {
                            return h
                        };
                        A(a, {
                            name: b,
                            fromWireType: g,
                            toWireType: c,
                            argPackAdvance: 8,
                            readValueFromPointer: eb(b, e, 0 !== d),
                            destructorFunction: null
                        })
                    }, _embind_register_memory_view: function (a, b, c) {
                        function d(g) {
                            g >>= 2;
                            var k = q;
                            return new e(k.buffer, k[g + 1], k[g])
                        }

                        var e = [Int8Array, Uint8Array, Int16Array, Uint16Array, Int32Array, Uint32Array, Float32Array, Float64Array][b];
                        c = t(c);
                        A(a, {name: c, fromWireType: d, argPackAdvance: 8, readValueFromPointer: d},
                            {ignoreDuplicateRegistrations: !0})
                    }, _embind_register_std_string: function (a, b) {
                        b = t(b);
                        var c = "std::string" === b;
                        A(a, {
                            name: b, fromWireType: function (d) {
                                var e = q[d >> 2], g = d + 4;
                                if (c) for (var k = g, l = 0; l <= e; ++l) {
                                    var h = g + l;
                                    if (l == e || 0 == r[h]) {
                                        var n = h - k;
                                        k = k ? Ea(r, k, n) : "";
                                        if (void 0 === m) var m = k; else m += String.fromCharCode(0), m += k;
                                        k = h + 1
                                    }
                                } else {
                                    m = Array(e);
                                    for (l = 0; l < e; ++l) m[l] = String.fromCharCode(r[g + l]);
                                    m = m.join("")
                                }
                                B(d);
                                return m
                            }, toWireType: function (d, e) {
                                e instanceof ArrayBuffer && (e = new Uint8Array(e));
                                var g, k = "string" ==
                                    typeof e;
                                k || e instanceof Uint8Array || e instanceof Uint8ClampedArray || e instanceof Int8Array || v("Cannot pass non-string to std::string");
                                if (c && k) for (var l = e, h = g = 0; h < l.length; ++h) {
                                    var n = l.charCodeAt(h);
                                    127 >= n ? g++ : 2047 >= n ? g += 2 : 55296 <= n && 57343 >= n ? (g += 4, ++h) : g += 3
                                } else g = e.length;
                                l = ja(4 + g + 1);
                                h = l + 4;
                                q[l >> 2] = g;
                                if (c && k) {
                                    if (k = r, g += 1, 0 < g) {
                                        g = h + g - 1;
                                        for (n = 0; n < e.length; ++n) {
                                            var m = e.charCodeAt(n);
                                            if (55296 <= m && 57343 >= m) {
                                                var p = e.charCodeAt(++n);
                                                m = 65536 + ((m & 1023) << 10) | p & 1023
                                            }
                                            if (127 >= m) {
                                                if (h >= g) break;
                                                k[h++] = m
                                            } else {
                                                if (2047 >=
                                                    m) {
                                                    if (h + 1 >= g) break;
                                                    k[h++] = 192 | m >> 6
                                                } else {
                                                    if (65535 >= m) {
                                                        if (h + 2 >= g) break;
                                                        k[h++] = 224 | m >> 12
                                                    } else {
                                                        if (h + 3 >= g) break;
                                                        k[h++] = 240 | m >> 18;
                                                        k[h++] = 128 | m >> 12 & 63
                                                    }
                                                    k[h++] = 128 | m >> 6 & 63
                                                }
                                                k[h++] = 128 | m & 63
                                            }
                                        }
                                        k[h] = 0
                                    }
                                } else if (k) for (k = 0; k < g; ++k) n = e.charCodeAt(k), 255 < n && (B(h), v("String has UTF-16 code units that do not fit in 8 bits")), r[h + k] = n; else for (k = 0; k < g; ++k) r[h + k] = e[k];
                                null !== d && d.push(B, l);
                                return l
                            }, argPackAdvance: 8, readValueFromPointer: X, destructorFunction: function (d) {
                                B(d)
                            }
                        })
                    }, _embind_register_std_wstring: function (a, b,
                                                               c) {
                        c = t(c);
                        if (2 === b) {
                            var d = fb;
                            var e = gb;
                            var g = hb;
                            var k = () => S;
                            var l = 1
                        } else 4 === b && (d = ib, e = jb, g = kb, k = () => q, l = 2);
                        A(a, {
                            name: c, fromWireType: function (h) {
                                for (var n = q[h >> 2], m = k(), p, w = h + 4, y = 0; y <= n; ++y) {
                                    var u = h + 4 + y * b;
                                    if (y == n || 0 == m[u >> l]) w = d(w, u - w), void 0 === p ? p = w : (p += String.fromCharCode(0), p += w), w = u + b
                                }
                                B(h);
                                return p
                            }, toWireType: function (h, n) {
                                "string" != typeof n && v("Cannot pass non-string to C++ string type " + c);
                                var m = g(n), p = ja(4 + m + b);
                                q[p >> 2] = m >> l;
                                e(n, p + 4, m + b);
                                null !== h && h.push(B, p);
                                return p
                            }, argPackAdvance: 8, readValueFromPointer: X,
                            destructorFunction: function (h) {
                                B(h)
                            }
                        })
                    }, _embind_register_value_object: function (a, b, c, d, e, g) {
                        aa[a] = {name: t(b), rawConstructor: O(c, d), rawDestructor: O(e, g), fields: []}
                    }, _embind_register_value_object_field: function (a, b, c, d, e, g, k, l, h, n) {
                        aa[a].fields.push({
                            fieldName: t(b),
                            getterReturnType: c,
                            getter: O(d, e),
                            getterContext: g,
                            setterArgumentType: k,
                            setter: O(l, h),
                            setterContext: n
                        })
                    }, _embind_register_void: function (a, b) {
                        b = t(b);
                        A(a, {
                            isVoid: !0, name: b, argPackAdvance: 0, fromWireType: function () {
                            }, toWireType: function (c, d) {
                            }
                        })
                    },
                    _emval_decref: Aa, _emval_incref: function (a) {
                        4 < a && (x.get(a).refcount += 1)
                    }, _emval_new_cstring: function (a) {
                        var b = Q.toHandle;
                        var c = mb[a];
                        a = void 0 === c ? t(a) : c;
                        return b.call(Q, a)
                    }, _emval_take_value: function (a, b) {
                        var c = F[a];
                        void 0 === c && v("_emval_take_value has unknown type " + Ba(a));
                        a = c;
                        a = a.readValueFromPointer(b);
                        return Q.toHandle(a)
                    }, abort: function () {
                        T("")
                    }, emscripten_memcpy_big: function (a, b, c) {
                        r.copyWithin(a, b, b + c)
                    }, emscripten_resize_heap: function (a) {
                        var b = r.length;
                        a >>>= 0;
                        if (2147483648 < a) return !1;
                        for (var c =
                            1; 4 >= c; c *= 2) {
                            var d = b * (1 + .2 / c);
                            d = Math.min(d, a + 100663296);
                            var e = Math;
                            d = Math.max(a, d);
                            e = e.min.call(e, 2147483648, d + (65536 - d % 65536) % 65536);
                            a:{
                                d = R.buffer;
                                try {
                                    R.grow(e - d.byteLength + 65535 >>> 16);
                                    na();
                                    var g = 1;
                                    break a
                                } catch (k) {
                                }
                                g = void 0
                            }
                            if (g) return !0
                        }
                        return !1
                    }, fd_close: function (a) {
                        return 52
                    }, fd_seek: function (a, b, c, d, e) {
                        return 70
                    }, fd_write: function (a, b, c, d) {
                        for (var e = 0, g = 0; g < c; g++) {
                            var k = q[b >> 2], l = q[b + 4 >> 2];
                            b += 8;
                            for (var h = 0; h < l; h++) {
                                var n = r[k + h], m = nb[a];
                                0 === n || 10 === n ? ((1 === a ? lb : I)(Ea(m, 0)), m.length = 0) : m.push(n)
                            }
                            e +=
                                l
                        }
                        q[d >> 2] = e;
                        return 0
                    }
                };
                (function () {
                    function a(c, d) {
                        c = c.exports;
                        f.asm = c;
                        R = f.asm.memory;
                        na();
                        ua = f.asm.__indirect_function_table;
                        Ia.unshift(f.asm.__wasm_call_ctors);
                        G--;
                        f.monitorRunDependencies && f.monitorRunDependencies(G);
                        0 == G && P && (d = P, P = null, d());
                        return c
                    }

                    var b = {env: Pa, wasi_snapshot_preview1: Pa};
                    G++;
                    f.monitorRunDependencies && f.monitorRunDependencies(G);
                    if (f.instantiateWasm) try {
                        return f.instantiateWasm(b, a)
                    } catch (c) {
                        I("Module.instantiateWasm callback failed with error: " + c), U(c)
                    }
                    Ua(M, L, b, function (c) {
                        a(c.instance)
                    }).catch(U);
                    return {}
                })();
                var ja = function () {
                    return (ja = f.asm.malloc).apply(null, arguments)
                }, B = function () {
                    return (B = f.asm.free).apply(null, arguments)
                }, Ca = function () {
                    return (Ca = f.asm.__getTypeName).apply(null, arguments)
                };
                f.__embind_initialize_bindings = function () {
                    return (f.__embind_initialize_bindings = f.asm._embind_initialize_bindings).apply(null, arguments)
                };
                var va = function () {
                    return (va = f.asm.__cxa_is_pointer_type).apply(null, arguments)
                };
                f.dynCall_vij = function () {
                    return (f.dynCall_vij = f.asm.dynCall_vij).apply(null, arguments)
                };
                f.dynCall_jiji = function () {
                    return (f.dynCall_jiji = f.asm.dynCall_jiji).apply(null, arguments)
                };
                var Z;
                P = function b() {
                    Z || Ha();
                    Z || (P = b)
                };
                if (f.preInit) for ("function" == typeof f.preInit && (f.preInit = [f.preInit]); 0 < f.preInit.length;) f.preInit.pop()();
                Ha();
                return ba.ready
            }
        })();
        Ra.exports = la
    })(ka);
    K = K.getDefaultExportFromCjs(ka.exports);
    K = Object.freeze(Object.defineProperty({__proto__: null, default: K}, Symbol.toStringTag, {value: "Module"}));
    Qa.i3s = K
});